import bd.org.apache.commons.math.linear.*

RealMatrix coefficients =
    new Array2DRowRealMatrix([[2, 3, -2], [-1, 7, 6], [4, -3, -5]] as double[][],
            false);
DecompositionSolver solver = new LUDecomposition(coefficients).getSolver();


RealVector constants = new ArrayRealVector([1, -2, 1] as double[], false);
RealVector solution = solver.solve(constants);

println solution
